package com.hrprojectback.dto;


import com.fasterxml.jackson.annotation.JsonFormat;
import org.springframework.stereotype.Component;

import java.util.Date;

@Component
public class User {
    private Integer userId;//用户id

    private String username;//用户名

    private String name;//姓名

    private String password;//密码

    private Integer gender;//性别

    private String email;//邮箱

    private String status;//员工状态

    // 使用@JsonFormat注解来指定日期格式

    private String birthDate;//出生日期

    private String entryDate;//入职日期

    private String deptName;//所属部门

    private String phone;//手机号

    private String address;//地址

    private String remark;//备注

    private Integer deptId;//所属部门id

    private String identity;//身份证号

    public User() {
    }

    public User(Integer userId, String username, String name, String password, Integer gender, String email, String status, String birthDate, String entryDate, String deptName, String phone, String address, String remark, Integer deptId, String identity) {
        this.userId = userId;
        this.username = username;
        this.name = name;
        this.password = password;
        this.gender = gender;
        this.email = email;
        this.status = status;
        this.birthDate = birthDate;
        this.entryDate = entryDate;
        this.deptName = deptName;
        this.phone = phone;
        this.address = address;
        this.remark = remark;
        this.deptId = deptId;
        this.identity = identity;
    }

    public Integer getUserId() {
        return userId;
    }

    public void setUserId(Integer userId) {
        this.userId = userId;
    }

    public String getUsername() {
        return username;
    }

    public void setUsername(String username) {
        this.username = username;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getPassword() {
        return password;
    }

    public void setPassword(String password) {
        this.password = password;
    }

    public Integer getGender() {
        return gender;
    }

    public void setGender(Integer gender) {
        this.gender = gender;
    }

    public String getEmail() {
        return email;
    }

    public void setEmail(String email) {
        this.email = email;
    }

    public String getStatus() {
        return status;
    }

    public void setStatus(String status) {
        this.status = status;
    }

    public String getBirthDate() {
        return birthDate;
    }

    public void setBirthDate(String birthDate) {
        this.birthDate = birthDate;
    }

    public String getEntryDate() {
        return entryDate;
    }

    public void setEntryDate(String entryDate) {
        this.entryDate = entryDate;
    }

    public String getDeptName() {
        return deptName;
    }

    public void setDeptName(String deptName) {
        this.deptName = deptName;
    }

    public String getPhone() {
        return phone;
    }

    public void setPhone(String phone) {
        this.phone = phone;
    }

    public String getAddress() {
        return address;
    }

    public void setAddress(String address) {
        this.address = address;
    }

    public String getRemark() {
        return remark;
    }

    public void setRemark(String remark) {
        this.remark = remark;
    }

    public Integer getDeptId() {
        return deptId;
    }

    public void setDeptId(Integer deptId) {
        this.deptId = deptId;
    }

    public String getIdentity() {
        return identity;
    }

    public void setIdentity(String identity) {
        this.identity = identity;
    }

    @Override
    public String toString() {
        return "User{" +
                "userId=" + userId +
                ", username='" + username + '\'' +
                ", name='" + name + '\'' +
                ", password='" + password + '\'' +
                ", gender=" + gender +
                ", email='" + email + '\'' +
                ", status='" + status + '\'' +
                ", birthDate=" + birthDate +
                ", entryDate=" + entryDate +
                ", deptName='" + deptName + '\'' +
                ", phone='" + phone + '\'' +
                ", address='" + address + '\'' +
                ", remark='" + remark + '\'' +
                ", deptId=" + deptId +
                ", identity='" + identity + '\'' +
                '}';
    }
}

